package com.etlmaster.rowprocessor.core;

import java.util.Map;

import com.etlmaster.rowprocessor.disruptor.readEvent.LineEvent;
import com.lmax.disruptor.RingBuffer;
import com.lmax.disruptor.dsl.Disruptor;

/**
 * @author Larry
 * @copyright Larry@etlMaster
 * @since 2017-09-10
 */
public abstract class AbstractOutPutPlugin extends AbstractPlugin{
	

	private RingBuffer<LineEvent> ringBuffer;

	private Disruptor<LineEvent> disruptor;
	
	
	public AbstractOutPutPlugin(String id,String jobId, String name, String code,
			Map<String, Object> paramMap,Map<String, Object> var) {
		super(id,jobId, name, code, paramMap,var);
	}

	public abstract void write() throws Exception;

	public RingBuffer<LineEvent> getRingBuffer() {
		return ringBuffer;
	}

	public void setRingBuffer(RingBuffer<LineEvent> ringBuffer) {
		this.ringBuffer = ringBuffer;
	}

	public Disruptor<LineEvent> getDisruptor() {
		return disruptor;
	}

	public void setDisruptor(Disruptor<LineEvent> disruptor) {
		this.disruptor = disruptor;
	}
	
}
